function hidebody(obj,type){
	var w = $(window).width();
	var h = document.documentElement.clientHeight || document.body.clientHeight;
	$('.float_bg').css({width:w,height:h}).show();
	var fw = obj.outerWidth(true);
	var fh = obj.outerHeight(true);
	switch(type){
			case 1:
			obj.show().css({top:0,left:Math.floor((w-fw)/2),'opacity':0});
			htmlbody(1);
	    setInterval(function(){
	    	obj.animate({top:Math.floor((h-fh)/2)-150,'opacity':1},500);
	    })
	    break;
	    case 2:
	    	obj.show().css({top:50,left:Math.floor((w-fw)/2)})
	}
 }
function htmlbody(type){
 	var temp_h1 = document.body.clientHeight;
    var temp_h2 = document.documentElement.clientHeight;          
    var isXhtml = (temp_h2<=temp_h1&&temp_h2!=0)?true:false;   
    var htmlbody = isXhtml?document.documentElement:document.body; 
    switch (type){
    	case 1:
    	  htmlbody.style.overflow = "hidden"; 
    	  break;
    	 case 2:
    	  htmlbody.style.overflow = "auto";  
    } 
  
 }
 function mesa(str){
 	var w = $(window).width();
	var h = document.documentElement.clientHeight || document.body.clientHeight;
	$('.mesage').css({left:Math.floor((w-300)/2),top:Math.floor((h-100)/2)});
	$('.mesage').html(str);
	$('.mesage').show().animate({opacity:1},500);
	setTimeout(function(){
			$('.mesage').animate({opacity:0},500,function(){
				 $('.mesage').hide();
			});
	},1000)
 }
 function close(type){
 	switch(type){
 		case 1: 		 	 
 		     $('.floater').animate({top:0,'opacity':0},500,function(){
 		     $('.float_bg').hide();
 		 	  htmlbody(2);
 		 });
 		 break;
 		 case 2:
 		   $('.float_bg').hide();
 		   htmlbody(2);
 		   break;
 		}

 }